package com.onec.service.manage.dto.user;

import com.onec.service.api.dto.response.BaseResponse;
import com.onec.service.api.enums.ResultCodeEnum;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.List;

/**
 * @author onec
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class UserMenuResp extends BaseResponse {


    private UserMenuInfo userMenuInfo;
    private List<UserMenuInfo> userMenuInfoList;

    public static UserMenuResp respOk(List<UserMenuInfo> userMenuInfoList) {
        UserMenuResp userMenuResp = new UserMenuResp(ResultCodeEnum.SUCCESS.getCode(), ResultCodeEnum.SUCCESS.getMessage());
        userMenuResp.userMenuInfoList = userMenuInfoList;
        return userMenuResp;
    }


    public UserMenuResp(int code, String message) {
        super(code, message);
    }
}
